package liczba;

import static org.junit.Assert.*;

import org.junit.After;
import org.junit.Before;
import org.junit.Ignore;
import org.junit.Test;

public class LiczbaTest4 {
	Liczba example = null;
	@Before
	public void startIt() throws Exception {
		example = new Liczba(5);
	}

	@After
	public void tearDown() throws Exception {
		example = null;
	}

	@Test
	public void test1() throws Exception {
		example.setNumb(1);
		assertEquals(example.toBase(6),"1");
	}
	@Test (expected=LiczbaException.class)
	public void test2() throws Exception {
		example.setNumb(-5);
		example.toBase(6);
	}
	@Ignore // The test case won't be run
	public void testBetter() throws Exception {
		example.setNumb(-5);
		example.toBase(-4);
	}
	@Test (timeout=1)
	public void test3() throws Exception {
		example.setNumb(456789);
		example.toBase(3);
	}
	@Test
	public void test17() throws Exception {
		example.setNumb(16);
		assertEquals(example.toBase(3),"g");
	}
	
	

}
